﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true" CodeBehind="ComfirmOrder.aspx.cs" Inherits="FYPHP.ComfirmOrder" %>
<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="LeftContent" runat="server">
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="MainContent" runat="server">
<script type="text/javascript">    var num = 0; </script>
<h2>Comfirm Order</h2>
<asp:Repeater ID="Repeater1" runat="server">
        <HeaderTemplate>
<table cellpadding="5" cellspacing="5" width="722" border="1px solid #ffffff" align="center" style="border-collapse: collapse; border-color: #aaaaaa; text-align: center; margin-top: 10px;">
 <tr style="background-color: #eee; font-weight: bold;"><td width="30px">No.</td><td>Product(s)</td><td>Quantity</td><td>Price</td><td>Subtotal</td></tr>
</HeaderTemplate>
        <ItemTemplate>
        <td><script type="text/javascript">                num += 1; document.write(num);</script></td>
            <td align="center"><%#DataBinder.Eval(Container.DataItem, "p_name" ) %></td>
            <td align="center"><%#DataBinder.Eval(Container.DataItem, "quantity" ) %></td>
            <td align="center"><%#DataBinder.Eval(Container.DataItem, "p_price" ) %></td>
            <td align="center"><%# processData(DataBinder.Eval(Container.DataItem, "quantity"), DataBinder.Eval(Container.DataItem, "p_price"))%></td>
        </tr>
        </ItemTemplate>
        <FooterTemplate></FooterTemplate>
        </asp:Repeater>
        <tr><td colspan="4" style="text-align: right; font-weight: bold">Total&nbsp;</td><td>
       <asp:Label ID="lblTotal" runat="server"></asp:Label></td></tr>
    </table>
    </form>

<form action="https://www.sandbox.paypal.com/cgi-bin/webscr" method="post">

   <input type="hidden" name="return" value="http://localhost:34874/SuccessTransaction.aspx"/>
   <input type="hidden" name="cancel_return" value="http://localhost:34874/CancelTransaction.aspx"/>

    <input type="hidden" name="cmd" value="_xclick" />
  
   
    <asp:Label ID="Label4" runat="server"></asp:Label>

    <span style="float: right; margin-top: 10px;"><input type="submit" value="Proceed To Payment" /></span>
    
</form>
</asp:Content>
